package com.partner.match.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.partner.match.model.dto.user.UserRegisterRequest;
import com.partner.match.model.entity.User;
import com.partner.match.model.vo.LoginUserVO;
import com.partner.match.model.vo.UserVO;

import javax.servlet.http.HttpServletRequest;
import java.util.List;

/**
 * @Author: jzz
 * @CreateTime: 2025-01-11
 * @Description: 用户Service
 */
public interface UserService extends IService<User> {
    /**
     * 查询用户标签
     *
     * @param tagsList 标签列表
     * @return
     */
    public List<UserVO> getUserTagsList(List<String> tagsList);

    /**
     * 获取全部用户
     *
     * @return
     */
    Page<User> recommendUsers(long currentPage, long pageSize, HttpServletRequest request);

    /**
     * 用户注册
     *
     * @param userName      昵称
     * @param userPassword  密码
     * @param userAccount   账户
     * @param checkPassword 检查密码
     * @param tags          标签
     * @return
     */
    public Long registerUser(String userName, String userPassword, String userAccount, String checkPassword, String tags);

    /**
     * 用户登录
     *
     * @param userAccount  账户
     * @param userPassword 密码
     * @param request
     * @return
     */
    LoginUserVO login(String userAccount, String userPassword, HttpServletRequest request);

    /**
     * 获取当前登录用户
     *
     * @param request
     * @return
     */
    LoginUserVO getCurrentUser(HttpServletRequest request);

    /**
     * 修改用户信息
     *
     * @param user    用户
     * @param request
     * @return
     */
    Boolean updateUser(User user, HttpServletRequest request);

    /**
     * 获取匹配用户
     *
     * @param num 匹配数量
     * @return
     */
    List<UserVO> matchUsers(Long num);
}
